1. Field of the Invention
The present invention relates to a connection establishing method and Bluetooth device, and more particularly, to a connection establishing method for establishing a connection with a master Bluetooth device using different hardware address according to a Bluetooth profile currently used, and Bluetooth device thereof.
2. Description of the Prior Art
Bluetooth, a short-distance wireless communication technique using 2.4 GHz frequency band, has advantages of low price, low power consumption and supporting audio and data transmission. Bluetooth technique has widespread applications. For example, cell phone users receive calls with Bluetooth headsets, and computers with Bluetooth keyboard and Bluetooth mouse connect to printers via a Bluetooth transmission interface, which largely decrease inconvenience of connecting to accessories via traditional cable lines. Or, all computers in a conference room perform data synchronization or share the Internet via the Bluetooth transmission interface. Besides the above applications in personal computer and mobile communication fields, the Bluetooth technique can also be applied in retail and warehouse businesses. For example, a Bluetooth barcode scanner is capable of transmitting scanned barcodes to the computers for tens of meters round, which enhances convenience of logistics management.
Services provided by Bluetooth devices are defined by Bluetooth profiles. Headset profile (HSP), cordless telephonyprofile (CTP), serial port profile (SPP), and human interface device profile (HID), are common profiles. The SPP replaces a traditional RS-232 transmission cable, and the HID realizes the Bluetooth keyboard, Bluetooth mouse, or Bluetooth joystick. Each Bluetooth device has a 6-byte hardware address, or medium access control (MAC) address, such as 00:4C:21:7F:D2:50.
When a master Bluetooth device obtains a hardware address of a slave Bluetooth device, and acquires that the hardware address is not yet paired with it, the master Bluetooth device triggers an automatically pairing process. Afterward, each time when the slave Bluetooth device connects with the master Bluetooth device, the master Bluetooth device is capable of recognizing a service provided by the slave Bluetooth device by the hardware address, so as to shorten time needed for pairing and accelerate connection speed. A normal Bluetooth device is capable of supporting one and upward Bluetooth profile, but can only establish a connection in only one Bluetooth profile at a time.
Take a prior art Bluetooth barcode scanner supporting the SPP and the HID as an example. The Bluetooth barcode scanner is a slave Bluetooth device that has to establish a connection with a computer as a master Bluetooth device. The computer preliminarily chooses to perform pairing in a profile of the Bluetooth barcode scanner, such as the SPP. Assume that a user adopts the SPP on the Bluetooth barcode scanner for a period of time and then changes settings to transmit barcode data in the HID, and in this situation, although the hardware address of the Bluetooth barcode scanner obtained by the computer is identical to the hardware address previously recorded, the computer can neither accurately receive the barcode data transmitted by the Bluetooth barcode scanner in the HID nor trigger a new pairing process with the Bluetooth barcode scanner in the HID since the corresponding Bluetooth service does not use the SPP previously paired in. Under such circumstances, the user has to manually delete the paired Bluetooth barcode scanner in the computer and manually controls the computer to perform re-pairing with the Bluetooth barcode scanner in the HID so as to use the Bluetooth barcode scanner normally.
From the above, in the prior art, each time when the user changes the Bluetooth profile in use, the user has to manually control the computer to perform re-pairing with the Bluetooth device. Accordingly, user convenience of the Bluetooth device is decreased.